home *** CD-ROM | disk | FTP | other *** search
- Path: news.dorsai.org!not-for-mail
- From: mongoose@dorsai.org (Jeff Yu)
- Newsgroups: comp.lang.c++
- Subject: How to read: operator overloaded <<
- Date: 21 Apr 1996 10:13:00 -0400
- Organization: The Dorsai Embassy, Inc.
- Message-ID: <4ldfpc$j0u@amanda.dorsai.org>
- NNTP-Posting-Host: amanda.dorsai.org
- X-Newsreader: TIN [version 1.2 PL2]
-
- Hi, I have hard time to understand the syntac of << operator overloaded
- declaration. As it is stated in Lippman's C++ Primer, the << sample is
- supposed to take TWO parameters: ostream& operator<<(ostream& os, String& s)
- But when using it, the way is: cout<<"test"<<MyScreen<<endl;
- Where is the second parameter if I consider the MyScreen as the first one?
-
- What is the difference from ostream& operator << (String &s)?
-
- Please help!
-
-